<?php
/* @var $this JamaahController */
/* @var $model Jamaah */

//$this->breadcrumbs=array(
//	'Jamaahs'=>array('index'),
//	'Manage',
//);
//
//$this->menu=array(
//	array('label'=>'List Jamaah', 'url'=>array('index')),
//	array('label'=>'Create Jamaah', 'url'=>array('create')),
//);

Yii::app()->clientScript->registerScript('search', "
/*$('.search-button').click(function(){
	$('.search-form').toggle();
	return false;
});*/
$('.search-form').toggle();
$('.search-form form').submit(function(){
	$.fn.yiiGridView.update('jamaah-grid', {
		data: $(this).serialize()
	});
	return false;
});
");
?>
<div class="judul2" style="padding:3px 15px">
			JAMAAH
</div>
<div style="background: #dedede repeat;"> 
<div style="width: 540px; padding:10px">
<?//php echo CHtml::link('Pencarian','#',array('class'=>'search-button')); ?>
<div class="search-form" style="display:none;padding-top:10px">
<?php $this->renderPartial('_search',array(
	'model'=>$model,
)); ?>
</div><!-- search-form -->

<?php 

$this->widget('zii.widgets.grid.CGridView', array(
	'id'=>'jamaah-grid',
	'dataProvider'=>$model->search(),
//	'filter'=>$model,
	'columns'=>array(	
    
     array(
            'header' => 'Data Jamaah',         
            'type' => 'html',
            'value' => 'U::tabeljamaah($data)',//'U::html(strtoupper($data["nama_kelompok"]),"'.bu().'/img/radio-button_off.gif","").U::html(ucwords($data->idKabupaten->nama_kabupaten),"'.bu().'/img/home.gif","")',
            //'value' => 'l(e($data["nama"]),url("/backend/berita/update/".$data["id"]))'
            'htmlOptions'=>array('width'=>'40px'),
        ), 	
        // array(
//          'header' => 'Gambar',
//          'name' => 'id_laskar',       
//          'type' => 'html',
//          'value' => 'img(bu()."/img/jamaah/foto/".$data->id_laskar.".jpg","",array("style"=>"width:100px;height:100px"))',
//          'htmlOptions'=>array('width'=>'100px'),
//        ),      
//         array(
//            'header' => 'Nama',
//            'name' => 'nama',
//            'value' => '$data["nama"]',
//            'htmlOptions'=>array('width'=>'100px'),
//        ), 
//        array(
//            'header' => 'Kelompok',
//            'name' => 'nama_kelompok',
//            'value' => '$data->idKelompok == null ? "-" : $data->idKelompok->nama_kelompok',
//            'htmlOptions'=>array('width'=>'100px'),
//        ),  
//        array(
//            'header' => 'Kabupaten',
//            'name' => 'nama_kabupaten',
//            'value' => '$data->idKabupaten->nama_kabupaten',
//            'htmlOptions'=>array('width'=>'100px'),
//        ),    
	  
	//	'no_ktp',
	//	'tempat_lahir',
	//	'tgl_lahir',
		/*
		'pekerjaan',
		'pekerjaan_lain',
		'hp1',
		'hp2',
		'tlp_rumah',
		'pin_bb',
		'email',
		'alamat_domisili',
		'sadziliyah',
		'qodiriyah',
		'lama_suluk',
		'id_kelompok',
		'status',
		'sa78',
		'laqodja',
		*/
		//array(
		///	'class'=>'CButtonColumn',
		//),
	),
)); ?>
</div>
</div>